package nc.ui.pu.metsettle.ace.action;

import nc.ui.pubapp.uif2app.actions.EditAction;
import nc.vo.pu.metsettle.entity.AggMetSettleBillHeaderVO;
import nc.vo.pub.lang.UFBoolean;

public class MetSettleEditAction extends EditAction {
	
	private static final long serialVersionUID = -5269693530613460368L;

	@Override
	protected boolean isActionEnable() {
		boolean isEnable = super.isActionEnable();
		AggMetSettleBillHeaderVO selectedData = (AggMetSettleBillHeaderVO) this.getModel().getSelectedData();
		if(null == selectedData)
			return isEnable;
		
		UFBoolean approveconfirm = selectedData.getParentVO().getApproveconfirm();
		if(null != approveconfirm && "Y".equals(approveconfirm.toString())) {
			isEnable = false;
		}
		return isEnable;
	}
}
